package com.lrkj.payfee.domain;

import java.util.Date;
import java.util.List;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.lrkj.common.annotation.Excel;
import com.lrkj.common.core.domain.BaseEntity;
import lombok.Data;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;

/**
 * 优惠政策对象 tb_favoured_policy
 *
 * @author yajun_ren
 * @date 2021-08-14
 */
@Data
public class FavouredPolicy extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** id */
    private String favouredPolicyId;

    /** 政策名称 */
    @Excel(name = "政策名称")
    private String favouredPolicyName;

    /** 小区ID */
    @Excel(name = "小区ID")
    private String communityId;

    /** 政策生效时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "政策生效时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date beginTime;

    /** 政策失效时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "政策失效时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date finishTime;

    /** 优惠方式 */
    @Excel(name = "优惠方式")
    private String preferentialMethod;

    /** 折后抹零 */
    @Excel(name = "折后抹零")
    private String wipeOff;

    /** 分摊方式 */
    @Excel(name = "分摊方式")
    private String sharingMethod;

    /** 优惠类型 */
    @Excel(name = "优惠类型")
    private String preferentialType;

    /** 折扣方式 */
    @Excel(name = "折扣方式")
    private String discountMethod;

    /** 减免方式 */
    @Excel(name = "减免方式")
    private String reliefMethod;

    /** 赠送方式 */
    @Excel(name = "赠送方式")
    private String largessMethod;

    /** 政策简介 */
    @Excel(name = "政策简介")
    private String synopsis;

    /** 系统类型 */
    @Excel(name = "系统类型")
    private String systemType;

    /** 状态 */
    @Excel(name = "状态")
    private String status;

    private String ancestors;

    private String deptId;

    //优惠设置
    List<FavouredConf> favouredConfs;

    //优惠政策收费标准
    List<FavouredNorm> favouredNorms;

    private Date findTime;


    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("favouredPolicyId", getFavouredPolicyId())
            .append("favouredPolicyName", getFavouredPolicyName())
            .append("communityId", getCommunityId())
            .append("beginTime", getBeginTime())
            .append("finishTime", getFinishTime())
            .append("preferentialMethod", getPreferentialMethod())
            .append("wipeOff", getWipeOff())
            .append("sharingMethod", getSharingMethod())
            .append("preferentialType", getPreferentialType())
            .append("discountMethod", getDiscountMethod())
            .append("reliefMethod", getReliefMethod())
            .append("largessMethod", getLargessMethod())
            .append("synopsis", getSynopsis())
            .append("systemType", getSystemType())
            .append("status", getStatus())
            .append("createBy", getCreateBy())
            .append("createTime", getCreateTime())
            .append("updateBy", getUpdateBy())
            .append("updateTime", getUpdateTime())
            .toString();
    }
}
